const mongoose = require('mongoose')
// 创建约束
const schema = new mongoose.Schema({
	createTime:{type:Date,default:Date.now},
	editTime:String,
	title: String,
	categories: Array,
	cover: String,
	tags: Array,
	body: String,
	check: {type:String, default:"未审核"},
	files:[{name:String, url:String,file_type:String }],
	editor_id:String
})
// 输出具备约束的model模型
module.exports = mongoose.model('Article', schema)
